package cn.by.wms.entity;

import java.time.LocalDateTime;

import cn.by.wms.enums.ShelfStatus;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;


 /**
 * 货架;
 * @author : heimi
 * @date : 2024-11-22
 */
@Data
@TableName("206_shelf")
public class Shelf extends BaseEntity {
    @TableId(type = IdType.AUTO)
    /** 货架Id */
    private Integer id ;
    /** 货架名称 */
    private String name ;
    /** 所属库房Id */
    private Integer warehouselId ;
    /** 货架状态 */
    private Integer status=1 ;
    @TableField(exist = false)
    private String statusX;
    /** 备注 */
    private String brief ;
    /** 排序 */
    private Integer seq ;

     public String getStatusX() {
         ShelfStatus productStatus = ShelfStatus.getProductStatusByCode(this.status);
         if (productStatus !=null){
             return productStatus.getMassage();
         }
         return statusX;
     }
 }